package com.wicket.okrapp.integration.dto;

import com.wicket.okrapp.common.dto.BaseDto;
import io.swagger.annotations.ApiModelProperty;
import java.io.Serializable;
import java.util.Objects;
import javax.validation.constraints.NotNull;
import lombok.Data;

/**
 * @desc CountNumberDataSetsDto
 * @使用场景
 */
@Data
public class CountNumberDataSetsDto extends BaseDto implements Serializable {

  /**
   * 通用主键ID
   */
  @NotNull(message = "通用主键ID不能为空")
  @ApiModelProperty("通用主键ID")
  private String commPrimaryKey;

  /**
   * 传输数值（整数型）
   */
  @NotNull(message = "传输数值（整数型）不能为空")
  @ApiModelProperty("传输数值（整数型）")
  private Long outputNum;

  @Override
  public boolean equals(Object o) {
    if (this == o) return true;
    if (o == null || getClass() != o.getClass()) return false;
    if (!super.equals(o)) return false;
    CountNumberDataSetsDto that = (CountNumberDataSetsDto) o;
    return commPrimaryKey == that.commPrimaryKey && outputNum == that.outputNum;
  }

  @Override
  public int hashCode() {
    return Objects.hash(super.hashCode(), commPrimaryKey, outputNum);
  }

}
